<?php
/*
 *author:Yangligao
 *Date:2013-10-4
 */
require 'Config.php';
require 'Public/Include/adv.php';
require 'Public/Include/footer.php';
require 'Public/Include/search.php';
require 'Public/Include/HotSort.php';
require 'Public/Include/latest.php';
$smarty->assign('positionFlag',"菜谱列表");
$menuModel = new MenuModel();
$pageSize = 6;
$total = $menuModel->menu_select("count(*) as num");
$totalCount = $total[0]['num'];
$pageModel = new Page($pageSize, $totalCount);
$start = $pageModel->getStart();
$menuData = $menuModel->menu_select('menu_id,menu_name,menu_pic','',"limit {$start},{$pageSize}");

$pageStr = $pageModel->getPageStr();
$smarty->assign('pageStr',$pageStr);

$smarty->assign('menuData',$menuData);
$smarty->display('Index/menulist.html');
?>
